package win.demonlegion.mapper;

import org.apache.ibatis.annotations.Mapper;
import org.apache.ibatis.annotations.Param;
import win.demonlegion.module.SysUserBean;

import java.util.List;

/**
 * 后台运营账号
 * Created by john on 2017/6/29.
 */
@Mapper
public interface SysUserMapper extends BaseMapper<SysUserBean> {
    SysUserBean login(@Param("username")String username, @Param("password")String password);
    int disableSysUser(@Param("id")String id);
    int enableSysUser(@Param("id")String id);
    int changePassword(@Param("id")String id, @Param("oldPassword")String oldPassword, @Param("newPassword")String newPassword);
    int resetPassword(@Param("id")String id, @Param("password")String password);
    List<String> getUserRole(@Param("userId")String userId);
    SysUserBean loadUserByUsername(@Param("username")String username);
}
